<script setup lang="ts">
const props = defineProps({
  data: {
    type: Object,
  },
})

interface Option {
  text: string
  value: string
}

const options = ref<Option[]>([
  { text: '有', value: '0' },
  { text: '无', value: '1' },
])
</script>

<template>
  <nut-cell-group v-if="props.data" title="证照信息">
    <nut-cell title="商户名称" :desc="props.data.merName" />
    <nut-cell title="商户简称" :desc="props.data.merShortName" />
    <option-select
      :model-value="props.data.businessStatus"
      title="是否有固定营业场所"
      readonly
      :options="options"
    />
    <nut-cell title="经营地址省市区" :desc="props.data.businessArea || '无'" />
    <nut-cell title="经营地址" :desc="props.data.businessAddr" />
  </nut-cell-group>
  <nut-skeleton
    v-else
    width="250px"
    height="15px"
    animated
    row="3"
  />
</template>

<style lang="sass" scoped>
.desc
  width: 200px
</style>
